<!DOCTYPE html>
<html>
  <head><meta name="generator" content="Hexo 3.9.0">
  <meta http-equiv="content-type" content="text/html; charset=utf-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=yes">
  
  
  <title>  通用策略文档 |   XHX Blog </title>

 
  
    <link rel="icon" href="/images/avatar.jpg">
  


  <link rel="stylesheet" href="/nayo.min.css"> 
</head>  
  <body>   
    
      <header class="header-wrapper">

  <nav class="inner">
    <div class="title">
      <a href="/">
        <img class="logo" src="/images/avatar.jpg">
      </a>
    </div>

    <ul class="menu">
      
      
      <li class="item">
        <a class="link" id="menu-home" href="/">
          <i class="iconfont icon-home">
        </i></a>
      </li>
      
      
      
      <li class="item">
        <a class="link" id="menu-archives" href="/archives">
          <i class="iconfont icon-archives">
        </i></a>
      </li>
      
      
      
      <li class="item">
        <a class="link" id="menu-tags" href="/tags">
          <i class="iconfont icon-tags">
        </i></a>
      </li>
      
      
      
      <li class="item">
        <a class="link" id="menu-about" href="/about">
          <i class="iconfont icon-about">
        </i></a>
      </li>
      
      
      
      <li class="item">
        <a class="link" id="menu-search">
          <i class="iconfont icon-search">
        </i></a>
        

        
      
    </li></ul>
  </nav>
</header>

<header class="mobile-header-wrapper">
  <i id="mobile-toggle" class="iconfont icon-menu mobile-toggle"></i>
</header>   

      <div class="container">       
          
          
            <div class="container-inner">  
          

          <article class="post slideDownMin">
  
	
<div class="header">
		<p class="title">	
			通用策略文档
		</p>
		<div class="info">	
			<time>
				Nov 26, 2019
			</time>

			
			
				<i class="iconfont icon-words"></i>
				<span class="words">437
				</span>
			
		</div>
</div> 
	

    <script type="text/x-mathjax-config">
        var post = document.getElementsByClassName("post")[0];  
        MathJax.Hub.Config({
            showProcessingMessages: false,
            messageStyle: "none",    
            tex2jax: {
                inlineMath:  [ ["$", "$"] , ["\\(","\\)"]],
                displayMath: [ ["$$","$$"] , ["\\[","\\]"]],
                skipTags: ['script', 'noscript', 'style', 'textarea', 'pre','code','a'],
            },
            "HTML-CSS": {            
                showMathMenu: false
            }
        });
        MathJax.Hub.Queue(["Typeset",MathJax.Hub,post]);
    </script>
    <style>.MathJax{outline:0;}</style>

    <script type="text/javascript" src="//cdn.bootcss.com/mathjax/2.7.2/latest.js?config=TeX-AMS-MML_HTMLorMML"></script>
 

	  <div class="typo post-content ">

		

			
					<h2 id="项目背景"><a href="#项目背景" class="headerlink" title="项目背景"></a>项目背景</h2><p>场景是根据一些条件去查询指定的结果，场景较多，如果每个场景都维护一套对应的库表和数据结构，成本过高而且不通用，这里用通用策略去配置，实现的效果是传入指定的策略code和条件数据可以得到对应的查询结果。<br>  在很多场景下，我们需要根据一些条件去查询结果，</p>
<h2 id="项目地址"><a href="#项目地址" class="headerlink" title="项目地址"></a>项目地址</h2><table>
<thead>
<tr>
<th></th>
<th>前端地址</th>
<th>管理地址</th>
</tr>
</thead>
<tbody><tr>
<td>测试环境</td>
<td><a href="http://wl.be.test.mi.com/oms" target="_blank" rel="noopener">http://wl.be.test.mi.com/oms</a></td>
<td><a href="http://wl.be.test.mi.com/oms/#/admin/common-strategy" target="_blank" rel="noopener">http://wl.be.test.mi.com/oms/#/admin/common-strategy</a></td>
</tr>
<tr>
<td>线上环境</td>
<td><a href="http://wl.be.mi.com/oms" target="_blank" rel="noopener">http://wl.be.mi.com/oms</a></td>
<td><a href="http://wl.be.mi.com/oms/#/admin/common-strategy" target="_blank" rel="noopener">http://wl.be.mi.com/oms/#/admin/common-strategy</a></td>
</tr>
<tr>
<td>* 如遇无法登陆请在工作台(<a href="http://wl.be.test.mi.com/work/" target="_blank" rel="noopener">测试</a>/<a href="http://wl.be.mi.com/work/" target="_blank" rel="noopener">线上</a>)添加系统权限。</td>
<td></td>
<td></td>
</tr>
</tbody></table>
<h2 id="使用指南"><a href="#使用指南" class="headerlink" title="使用指南"></a>使用指南</h2><h3 id="1-创建策略集"><a href="#1-创建策略集" class="headerlink" title="1. 创建策略集"></a>1. 创建策略集</h3><h3 id="2-定义策略集字段"><a href="#2-定义策略集字段" class="headerlink" title="2. 定义策略集字段"></a>2. 定义策略集字段</h3><h3 id="3-创建策略"><a href="#3-创建策略" class="headerlink" title="3. 创建策略"></a>3. 创建策略</h3><h3 id="4-选择策略字段"><a href="#4-选择策略字段" class="headerlink" title="4. 选择策略字段"></a>4. 选择策略字段</h3><h3 id="5-下载策略和基础数据"><a href="#5-下载策略和基础数据" class="headerlink" title="5. 下载策略和基础数据"></a>5. 下载策略和基础数据</h3><h3 id="6-填写好策略数据，并导入"><a href="#6-填写好策略数据，并导入" class="headerlink" title="6. 填写好策略数据，并导入"></a>6. 填写好策略数据，并导入</h3><h3 id="7-定义该策略的匹配规则"><a href="#7-定义该策略的匹配规则" class="headerlink" title="7. 定义该策略的匹配规则"></a>7. 定义该策略的匹配规则</h3><h3 id="8-通过系统第三方X5接口查询策略数据"><a href="#8-通过系统第三方X5接口查询策略数据" class="headerlink" title="8. 通过系统第三方X5接口查询策略数据"></a>8. 通过系统第三方X5接口查询策略数据</h3>  	
					
	  </div>     
	  

	<div class="bottom">
  <div class="other">
    <div class="meta">
      

      
      <i class="iconfont icon-tag"></i>
      <a class="tag-link" href="/tags/mi/">mi</a>
      
    </div>

    <div class="operate">
      
      <span class="text">Share</span>
      <ul class="share">
	   			             
        <li class="iconfont 
		icon-share-qq 
		-mob-share-qq 
		item"></li>		
   	   			             
        <li class="iconfont 
		icon-share-weixin 
		-mob-share-weixin 
		item"></li>		
   	   			             
        <li class="iconfont 
		icon-share-weibo 
		-mob-share-weibo 
		item"></li>		
   	   
</ul>	

<script id="-mob-share" src="https://f1.webshare.mob.com/code/mob-share.js?appkey=21d601593a1de"></script>
      
    </div>
  </div>


  
  <nav class="nav">
    <div class="link">
      
    </div>
    <div class="link">
      
      <a href="/2020/01/05/规则配置平台/" class="link-wrap">
        <strong class="caption">newer</strong>
        
        <span class="title">
          规则配置平台
        </span>
      </a>
      
    </div>
  </nav>
  
</div> 
	
<div class="comment">

    

    <div id="comment">
    </div>

    <script src="//cdn1.lncld.net/static/js/3.0.4/av-min.js"></script>

    <script src="//unpkg.com/valine@v1.1.8-beta/dist/Valine.min.js"></script>

    <script>
        new Valine({
            el: '#comment',
            notify: false,
            verify: false,
            app_id: 'cFM0eCo0CQ9xmBXmHi1eltol-gzGzoHsz',
            app_key: 'oh9tizsnvV2vNvWgqEvoNtQO',
            path: window.location.pathname,
            avatar: 'mm',
            guest_info: ['nick', 'mail']
        });
    </script>
    
</div>	
</article>

          </div> 
      </div>            
    
        <i id="toTop" class="iconfont icon-backtotop"></i>

  
    <div class="none" id="search">
    <div class="header">
        <input type="text" placeholder="Typing Something here." id="search-input" class="input">
        
        <i id="search-cancel" class="iconfont icon-cancel"></i>
    </div>

    <div id="search-result" class="result"></div>
</div>
     <div class="mobile-menu">      

      
      <img class="mobile-menu-icon" src="/images/avatar.jpg">  
      

         
            

            <a class="mobile-menu-link" href="/">Home
            </a>
            
         
            

            <a class="mobile-menu-link" href="/archives">Archives
            </a>
            
         
            

            <a class="mobile-menu-link" href="/tags">Tags
            </a>
            
         
            

            <a class="mobile-menu-link" href="/about">About
            </a>
            
         
                          

            <a class="mobile-menu-link mobile-menu-search" href="#">Search </a>                 
            
         
      
</div>
        
    



     
    


<footer class="footer">
	<div class="inner">
		<div class="copyright">
			&copy;
			
			2019 -
			
			2020
			Lemon

			<br>
			By <a href="https://hexo.io" target="_blank">Hexo</a> Theme <a href="https://github.com/Lemonreds/hexo-theme-Nayo" target="_blank">Nayo</a>
		</div>
	</div>
</footer>   

    <script src="/nayo.bundle.js"></script>           
  </body>        
</html>